package com.mrjoew.weekend.services.impl.bz;

import com.mrjoew.weekend.entities.po.ContentSecurityPO;
import com.mrjoew.weekend.repositories.bz.ContentSecurityRepository;
import com.mrjoew.weekend.services.bz.ContentSecurityService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.data.domain.Page;
import org.springframework.data.domain.Pageable;
import org.springframework.stereotype.Service;

import javax.transaction.Transactional;

/**
 * @author Christopher Jones
 * @ClassName ContentSecurityServiceImpl
 * @explain
 * @date 2020/6/21 0021 22:11
 */
@Transactional
@Service
public class ContentSecurityServiceImpl implements ContentSecurityService {

    @Autowired
    private ContentSecurityRepository contentSecurityRepository;

    @Override
    public void say(ContentSecurityPO po) {
        contentSecurityRepository.save(po);
    }

    @Override
    public Page<ContentSecurityPO> all(Pageable pageable) {
        return contentSecurityRepository.findAll(pageable);
    }
}
